import request from "@/utils/request";
import { getToken } from "@/utils/localToken";
import { IModuleUserInfo } from "./data";

export async function detailData(): Promise<any> {
	const token = getToken();
	return request({ url: `/admin/getInfo?token=${token}` });
}

export async function update(param: IModuleUserInfo): Promise<any> {
	return request({
		url: "/admin/",
		data: param,
		method: "put",
	});
}

export async function updateOwners(param: IModuleUserInfo): Promise<any> {
	return request({
		url: "/owners/",
		data: param,
		method: "put",
	});
}

export async function updateEmployees(param: IModuleUserInfo): Promise<any> {
	return request({
		url: "/employees/",
		data: param,
		method: "put",
	});
}




